/*
* $Id: InfoDrawer.h 122 2010-07-22 17:05:50Z volok-aleksej@yandex.ru $
*
* Copyright 2010 by Volokitin Alexey
* All rights reserved
*
*/
#ifndef _INFO_DRAWER_H_
#define _INFO_DRAWER_H_

#include "../Drawer.h"
#include "InfoItem.h"

class CInfoDrawer : public CDrawer
{
	int m_nPosY;
	int m_nPosX;
	int m_nSel;
	std::vector<CInfoItem*> m_aItems;
public:
	CInfoDrawer(IWnd* pParent);
	~CInfoDrawer();
public:
	void SetSel(int sel);
	int GetSel();
	int GetId(int sel);
public:
	void Clear();
	int InsertItem(int item, int nId, bool bButton = true);
	int AddItem(int nId, bool bButton = true);
	void AddSubItem(int numItem, InfoItem item);
public:
	bool ProcessMouse(unsigned int nButton, CPoint pos, int param);
public:
	void SetSizeCx(int nSize);
	void SetBeginPosY(int nPos);
	void SetBeginPosX(int nPos);
	int GetSizeY();
	int GetMinWidth();
public:
	virtual bool IsValidDrawer(Drawer::typeDrawer nType);
	virtual void Paint(CDC* dc, CRect rect);
};

#endif/*_INFO_DRAWER_H_*/